<!DOCTYPE html>
<html>
	<head>
		<meta charset="UTF-8">
		<title></title>
		<link rel="stylesheet" type="text/css" href="js/bootstrap-3.3.5-dist/css/bootstrap.min.css"/>
		<script src="js/jquery.js" type="text/javascript" charset="utf-8"></script>
		<script src="js/bootstrap-3.3.5-dist/js/bootstrap.min.js" type="text/javascript" charset="utf-8"></script>
		<style type="text/css">
			body{
				padding-top: 70px;
			}
		</style>
	</head>
	<body>
		<nav class="nav  navbar-inverse navbar-fixed-top" role="navigation">
		<div class="container-fluid">
			<div class="navbar-header">
				<a href="#" class="navbar-brand">首页</a>
			</div>
		
		   <div>
		   	<ul class="nav navbar-nav">
		   		<li class="active"><a href="#">话题</a></li>
		   		<li><a href="#">发现</a></li>
		   		<li><a href="发帖.html">发帖</a></li>
		   		<li><a href="#">##</a></li>
		   		<li><a href="#">##</a></li>
		   	</ul>
		   	<form class="navbar-form navbar-left" role="Search">
		   	<div class="form-group">
		   		<input type="text" class="form-control" placeholder="Search" />
		   		<button class="btn navbar-btn" type="submit">搜索</button>
		   	</div>
		   	</form>
		   	<ul class="nav navbar-nav navbar-right">
		   		<li><a href="#">登陆</a></li>
		   		<li><a href="#">注册</a></li>
		   	</ul>
		   </div>
		 </div>
		</nav>
		
		<div id="content">
			
		</div>
		
		<script type="text/javascript" charset="UTF-8">
//			$(document).ready(function(){
				$.ajax({
					type:"post",
					url:"MakeHomePage",
					async:true,
					success:function(data){
						var jsonObj=jQuery.parseJSON(data);
						html="<div><ul class='list-group'>";
						$.each(jsonObj, function(i,obj) {
							html+="<li id='" + obj.id +  "' type='none' class='list-group-item'>" ;
							html+="<a href='MakeBody.html?id="+obj.id+"'>"+obj.title+"</a></li>"
						});
						html+="</ul></div>";
						$("#content").append(html);
					}
				});
//				$("a").click(function(){
//					$.ajax({
//						type:"post",
//						url:"MakeBodySer",
//						async:true
//					});
//				});
//			})

		</script>
	</body>
</html>
